/*
 * fbank.com Inc.
 * Copyright (c) 2020 All Rights Reserved.
 * create by fm
 * date:2020-04-28
 *
 */
package com.ouwen.smartpay.service;

import com.fm.core.common.service.EntityService;
import com.ouwen.smartpay.entity.OrderDetail;

/**
 * openapi_order_detail Service接口
 * <p>
 * Date: 2020-04-28 23:14:08
 *
 * @author fm
 */
public interface OrderDetailService extends EntityService<OrderDetail> {

    /***
     *
     * 通过orderid查找OrderDetail
     *
     * @author liyong
     * @date 11:19 PM 2020/4/28
     * @param orderId
     * @exception
     * @return com.fbank.smartpay.entity.OrderDetail
     **/
    OrderDetail findOrderDetailRequestInfoByOrderId(Long orderId, String partnerId, String subPartnerId);

    /***
     *
     * 通过orderid查找OrderDetail
     *
     * @author liyong
     * @date 11:19 PM 2020/4/28
     * @param orderId
     * @exception
     * @return com.fbank.smartpay.entity.OrderDetail
     **/
    OrderDetail findOrderDetailResponseInfoByOrderId(Long orderId, String partnerId, String subPartnerId);

    /***
     *
     * 保存OrderDetail和写入缓存
     *
     * @author liyong
     * @date 11:40 AM 2020/5/7
     * @param partnerId
     * @param subPartnerId
     * @param orderDetail
     * @exception
     * @return void
     **/
    void saveOrderDetailAndCache(String partnerId, String subPartnerId, OrderDetail orderDetail);

    /***
     *
     * 更新订单详细信息，并删除缓存
     *
     * @author liyong
     * @date 11:49 AM 2020/5/7
     * @param partnerId
 * @param subPartnerId
 * @param orderDetail
     * @exception
     * @return void
     **/
    void updateOrderDetail(String partnerId, String subPartnerId, OrderDetail orderDetail);

    OrderDetail findOrderDetailByOrderId(Long orderId);

    void updateNotifyInfo(Long id, String notifyInfo);

}
